package kni.hoid;

import android.app.ListActivity;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;

public class NavigateActivity extends ListActivity {
    // this part removes duplicates in the array, sorts it, then inflates it out
    @Override
    public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
//      Set<String> set = new HashSet<String>(Arrays.asList(songlist));
//      String[] array4 = (set.toArray(new String[set.size()]));
//      Arrays.sort(array4);
//      setListAdapter(new ArrayAdapter<String>(this, R.layout.list_item, array4));
//
//      ListView lv = getListView();
//      lv.setTextFilterEnabled(true);
//
//      lv.setOnItemClickListener(new OnItemClickListener() {
//        public void onItemClick(AdapterView<?> parent, View view,
//            int position, long id) {
//          // When clicked, show a toast with the TextView text
//          Toast.makeText(getApplicationContext(), ((TextView) view).getText(),
//              Toast.LENGTH_SHORT).show();
//        }
//
//	
//      });
//      startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("google.navigation:q=12.491517,16.592222")));
      startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("google.navigation:q=mzk+brno")));
      
}
    // this array will be modified to contain the list of artists titles
    static final String[] songlist = new String[] {
        "Daiwa", "Nike", "Fifa", "Microsoft", "Apple", "Coke", "Pepsi", "Google", "Sony", "Vaio", "Acer", "HP",
        "Lenovo", "Mac", "PC", "Search Engine", "Office", "Soft Drink", "Chicken", "Duck", "Swan", "Daiwa", "Nike", "Fifa", "Microsoft", "Apple", "Coke", "Pepsi", "Google", "Sony", "Vaio", "Acer", "HP",
        "Lenovo", "Mac", "PC", "Search Engine", "Office", "Soft Drink", "Chicken", "Duck", "Swan", "Daiwa", "Nike", "Fifa", "Microsoft", "Apple", "Coke", "Pepsi", "Google", "Sony", "Vaio", "Acer", "HP",
        "Lenovo", "Mac", "PC", "Search Engine", "Office", "Soft Drink", "Chicken", "Duck", "Swan", "Daiwa", "Nike", "Fifa", "Microsoft", "Apple", "Coke", "Pepsi", "Google", "Sony", "Vaio", "Acer", "HP",
        "Lenovo", "Mac", "PC", "Search Engine", "Office", "Soft Drink", "Chicken", "Duck", "Swan"
      };
}
